package com.ai.mapper.made;


import com.ai.entity.cameraFunctions.functions.CameraFunctionsPO;
import com.ai.entity.cameraFunctions.functions.FunctionBasicsVO;
import com.ai.entity.made.CameraByFunctionParam;
import com.ai.entity.made.camera.CameraPO;
import com.ai.entity.made.camera.CameraVO;
import com.ai.entity.made.camera.SwitchCameraFunctionAlgorithmBO;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.ArrayList;
import java.util.List;

/**
 * <p>
 * Mapper 接口
 * </p>
 *
 * @author Mr.Chen
 * @since 2020-11-15
 */
@Repository
public interface CameraFunctionsMapper extends BaseMapper<CameraFunctionsPO> {
    List<FunctionBasicsVO> unchecked(int cameraId, String nickname);

    List<FunctionBasicsVO> checked(int cameraId, String nickname);

    List<SwitchCameraFunctionAlgorithmBO> selectFunction(int cameraId);

    List<SwitchCameraFunctionAlgorithmBO> selectFunctionByCameraIdAndFunctionType(@Param("cameraId") int cameraId, @Param("functionType") int functionType);

    List<CameraVO> listCameraByFunction(int functionId);

    List<CameraVO> listCameraByFunctionType(int type);

    List<Integer> listFunctionType(int cameraId);

    List<CameraPO> getCameraSteelList(@Param("funTypeList") ArrayList<Integer> funTypeList);

    /**
     * 根据功能type获取摄像头信息
     *
     * @param cameraByFunctionParam
     * @return
     */
    List<CameraVO> getCameraListByFunctionType(@Param("cameraByFunctionParam") CameraByFunctionParam cameraByFunctionParam
    );

}
